package com.interswitchng.services;

public class WebPayServiceProxy implements com.interswitchng.services.WebPayService_PortType {
  private String _endpoint = null;
  private com.interswitchng.services.WebPayService_PortType webPayService_PortType = null;
  
  public WebPayServiceProxy() {
    _initWebPayServiceProxy();
  }
  
  public WebPayServiceProxy(String endpoint) {
    _endpoint = endpoint;
    _initWebPayServiceProxy();
  }
  
  private void _initWebPayServiceProxy() {
    try {
      webPayService_PortType = (new com.interswitchng.services.WebPayService_ServiceLocator()).getBasicHttpBinding_WebPayService();
      if (webPayService_PortType != null) {
        if (_endpoint != null)
          ((javax.xml.rpc.Stub)webPayService_PortType)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
        else
          _endpoint = (String)((javax.xml.rpc.Stub)webPayService_PortType)._getProperty("javax.xml.rpc.service.endpoint.address");
      }
      
    }
    catch (javax.xml.rpc.ServiceException serviceException) {}
  }
  
  public String getEndpoint() {
    return _endpoint;
  }
  
  public void setEndpoint(String endpoint) {
    _endpoint = endpoint;
    if (webPayService_PortType != null)
      ((javax.xml.rpc.Stub)webPayService_PortType)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
    
  }
  
  public com.interswitchng.services.WebPayService_PortType getWebPayService_PortType() {
    if (webPayService_PortType == null)
      _initWebPayServiceProxy();
    return webPayService_PortType;
  }
  
  public org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryResponse getTransactionDataLegacy(org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryRequest transactionQueryRequest) throws java.rmi.RemoteException{
    if (webPayService_PortType == null)
      _initWebPayServiceProxy();
    return webPayService_PortType.getTransactionDataLegacy(transactionQueryRequest);
  }
  
  public org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryResponse getTransactionData(org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryRequest transactionQueryRequest) throws java.rmi.RemoteException{
    if (webPayService_PortType == null)
      _initWebPayServiceProxy();
    return webPayService_PortType.getTransactionData(transactionQueryRequest);
  }
  
  public org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryResponse getTransactionAcquirerData(org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.TransactionQueryRequest transactionQueryRequest) throws java.rmi.RemoteException{
    if (webPayService_PortType == null)
      _initWebPayServiceProxy();
    return webPayService_PortType.getTransactionAcquirerData(transactionQueryRequest);
  }
  
  public org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.CardRetrievalResponse retrievePan(org.datacontract.schemas._2004._07.WebPAY_Core_ServiceFramework_Contract.CardRetrievalRequest requestObject) throws java.rmi.RemoteException{
    if (webPayService_PortType == null)
      _initWebPayServiceProxy();
    return webPayService_PortType.retrievePan(requestObject);
  }
  
  
}